<template>
  <h6>appDome</h6>
  <h6>{{ firstName }}</h6>

  <input type="text" v-model="firstName" name="" id="" />
</template>

<script lang="ts">
import { defineComponent } from "vue";
// 导入ref
import { ref } from "vue";
export default defineComponent({
  name: "App",
  // 组合式API入口

  setup() {
    // 定义参数
    const firstName = ref("halon");
    const onClickHandler = () => {
      firstName.value = "freelaeder";
    };
    // 返回值
    return { firstName, onClickHandler };
  },
  components: {},
});
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
